package com.estate.utils;

public class RoleUtil {

	public static int getRoleInt(String roleString){
		int role = 0;
		
		if("总管理员".equals(roleString)){
			role = 1;
		}else if("会计".equals(roleString)){
			role = 2;
		}else if("造价".equals(roleString)){
			role = 3;
		}else if("招标代理".equals(roleString)){
			role = 4;
		}
		
		return role;
	}
	
	public static String getRoleString(int roleInt){
		String role = "";
		
		if(roleInt == 1){
			role = "总管理";
		}else if(roleInt == 2){
			role = "会计";
		}else if(roleInt == 3){
			role = "造价";
		}else if(roleInt == 4){
			role = "招标代理";
		}
		
		return role;
	}
}
